#import "UTEPedSdkPlugin.h"
#import <UTEBluetoothRYApi/UTEBluetoothRYApi.h>
#import "UTEPedMethodCallHandler.h"

@implementation UTEPedSdkPlugin
+ (void)registerWithRegistrar:(NSObject<FlutterPluginRegistrar>*)registrar {
    
    [[UTEBluetoothMgr sharedInstance] initUTEMgr];
    
    [[UTEPedMethodCallHandler shareInstance] initWithRegistrar:registrar];
    
    UTEPedSdkPlugin* instance = [[UTEPedSdkPlugin alloc] init];
    FlutterMethodChannel* channel = [FlutterMethodChannel methodChannelWithName:@"uteped_sdk/method" binaryMessenger:[registrar messenger]];
    
    [registrar addMethodCallDelegate:instance channel:channel];
}

- (void)handleMethodCall:(FlutterMethodCall*)call result:(FlutterResult)result {
    [[UTEPedMethodCallHandler shareInstance] handleMethodCall: call result: result];
}

@end
